The present invention relates to an image processing apparatus and method for segmenting an image into a plurality of blocks, and expressing color by a label in accordance with the feature amount of each block, and a storage medium.
In recent years, various techniques for searching, e.g., images have been proposed. Of such techniques, a technique for inputting an image used in a search (to be referred to as a query image hereinafter), and searching registered images for an image which is most similar to the query image is known. In such technique that has been developed to a given practice level, an image is segmented into a plurality of blocks, and the color histogram of each block is computed to determine the color that appears most frequently in each block. On the other hand, for example, an RGB color space is segmented into cells (small color space segments), and labels are assigned to those cells, as shown in FIG. 6. Then, the correspondence between the color that appears most frequency in a given block and the color label is determined for all the blocks to obtain a color label string.
The color label string is registered in a database, that of a query image is similarly detected, and pattern matching between these color labels is made to find a registered image which is most similar to the query image. As such technique, for example, Japanese Patent Laid-Open Nos. 8-249349, 10-260983, and the like are known.
However, if there are two different types of such image search apparatuses, when they segment a color space into different numbers of cells, or segment an image into different numbers of blocks, their color label strings cannot be commonly used. For this reason, a feature amount must be extracted from an original image.
Also, as the number of blocks obtained by segmenting an image becomes smaller (coarser segmentation), dominant colors (most of them are background colors) of the entire image occupy most labels of a color label string, and the colors of an object which is present in the background are lost. In this case, especially, since the aforementioned image search apparatus can only make a search using the background color, too many search results are output, and the user cannot easily obtain a desired image.
The present invention has been made in consideration of the aforementioned problems, and has as its first object to provide an image processing apparatus and method, which can convert given color label string data into another color label string data without requiring any original image, and a storage medium.
It is the second object of the present invention to provide an image processing apparatus and method, which can convert given color label string data into another color label string data after the dominant background color of an original image is excluded, and a storage medium.
In order to achieve the above objects, an image processing apparatus according to the first invention comprises the following arrangement.
That is, an image processing apparatus which segments an image into a plurality of blocks, and expresses the image by color label string data by assigning color labels to the segmented blocks in correspondence with feature amounts, comprises:
input means for inputting source color label string data and attribute information thereof;
designation means for designating attribute information of converted color label string data; and
conversion means for converting the source color label string data into destination color label string data on the basis of the attribute information input by the input means, and the attribute information designated by the designation means.
Also, an image processing apparatus according to the second invention comprises the following arrangement.
That is, an image processing apparatus which segments an image into a plurality of blocks, and expresses the image by color label string data by assigning color labels to the segmented blocks in correspondence with feature amounts, comprises:
input means for inputting source color label string data and attribute information thereof;
determination means for determining a background color of a source image on the basis of the color label string data input by the input means;
designation means for designating attribute information of converted color label string data; and
conversion means for converting the source color label string data into destination color label string data on the basis of the attribute information input by the input means, the attribute information designated by the designation means, and a determination result of the determination means.